package com.htht.job.core.util;


public enum ReturnCodeEnum {
	SUCCESS("0", "成功"), 
	FIAL("1", " 失败"),
	
	/**==========101 100===============**/
	ReturnCodeEnum_101_ERROR("101","固定参数为空"),
	ReturnCodeEnum_102_ERROR("102","outputlog为空"),
	ReturnCodeEnum_103_ERROR("103","inputxml为空"),
	ReturnCodeEnum_104_ERROR("104","exePath为空"),
	ReturnCodeEnum_105_ERROR("105","scriptFile为空"),
	ReturnCodeEnum_106_ERROR("106","outputxml为空"),
	ReturnCodeEnum_107_ERROR("107","输入参数为空"),
	ReturnCodeEnum_108_ERROR("108","拼装xml map失败"),
	ReturnCodeEnum_109_ERROR("109","创建文件失败"),
	ReturnCodeEnum_110_ERROR("110","demoHanderService执行失败"),

	/**==========201 AppJobInfo 200===============**/
	ReturnCodeEnum_201_ERROR("201","taskType不能为空");










	private String key;
	private String value;

	private ReturnCodeEnum(String key, String value) {
		this.key = key;
		this.value = value;
	}

	public String getKey() {
		return key;
	}

	public void setKey(String key) {
		this.key = key;
	}

	public String getValue() {
		return value;
	}

	public void setValue(String value) {
		this.value = value;
	}

	public static String getValue(String key) {
		for (ReturnCodeEnum st : ReturnCodeEnum.values()) {
			if (key.equals(st.key)) {
				return st.value;
			}
		}
		return "";
	}
}
